#ifndef _ALTITUDE_H_
#define _ALTITUDE_H_
#include "bmp180.h"
#include "ms5611.h"
#include "FBM320.H"

#define ALTLENGTH 10
#define HALENGTH 5
typedef struct
{
	float filter[ALTLENGTH];
	float bias;
	unsigned char index;
	unsigned char flag;
}ALTFIFO;

//typedef struct
//{
//	float altitude;
//	float temperature;
//	float pressure;
//}ALTITUDE;

//extern ALTITUDE Altitude;
extern float ALTitude;
float getEstimatedAltitude(void);
void Baro_Init(void);
void Baro_Calibration(void);
void Baro_Update(float dt);

#endif
